function corner0
global lam
clf

clf
% get(gcf)
set(gcf,'Position', [25 1115 658 230])
subaxis(1,1,1,1,'MT',0.01,'MB',0.23,'MR',-0.02,'ML',0.038,'P',0.04)

na=100;
yc=linspace(1,sqrt(3),na);
for i=1:na
	tc(i)=log(yc(i)/sqrt(3))-0.5*(yc(i)^2-3);
end

%  initial values
%lam=20;
%ep=1/lam;
ep=0.05;
lam=1/ep;
%tmax=1-log(sqrt(3))+0.1
tmax=2.5;
y10=sqrt(3); y20=0;
y0=[y10 y20];
% calculate solution using a MATLAB routine
options = odeset('RelTol', 1e-6,'AbsTol',1e-6);
[t,y] = ode45(@rhs,[0 tmax],y0,options);

hold on
%plot(tc,yc,'b','LineWidth',1.5)
plot(t,y(:,1),'b','LineWidth',1.8)

%  initial values
% lam=200;
% ep=1/lam;
ep=0.01;
lam=1/ep;
%tmax=1-log(sqrt(3))+0.1;
%tmax=1.5;
y10=sqrt(3); y20=0;
y0=[y10 y20];
% calculate solution using a MATLAB routine
options = odeset('RelTol', 1e-6,'AbsTol',1e-6);
[t2,y2] = ode45(@rhs,[0 tmax],y0,options);
plot(t2,y2(:,1),'--r','LineWidth',1.8)

xlabel('\tau-axis','FontWeight','bold')
ylabel('y-axis','FontWeight','bold')
grid on

box on
set(gca,'FontSize',16,'FontWeight','bold')

% na=100;
% tau1=1-log(sqrt(3));
% tau=linspace(tau1-0.1,tau1+0.0425,na);
% for i=1:na
%     tauC(i)=(tau(i)-tau1)/ep^(4/3);
% 	yC(i)=1-ep^(2/3)*airy(1,-tauC(i))/airy(-tauC(i));
% end
% plot(tau,yC,'color',[0 0.5 0],'LineWidth',1.5)
% 
axis([0 tmax -2.4 2.4])
% legend({' Outer',' Numerical',' Corner'},'Location','SouthWest')

exportgraphics(gcf,'/Users/mark/Desktop/van3.pdf')

hold off

%  define f(t,y)
function dy=rhs(t,y)
global lam
dy=zeros(2,1);
dy(1) = lam^2*(y(1)*(1-y(1)^2/3)-y(2));
dy(2) = y(1);








